import java.util.Stack;

public class E15_Stack {

	public static void main(String[] args) {
		Stack<Character> stack = new Stack<Character>();
		char[] chars = "+U+n+c---+e+r+t---+a-+i-+n+t+y---+ -+r+u--+l+e+s---".toCharArray();

		for (int i = 0; i < chars.length; i++) {
			switch (chars[i]) {
			case '+':
				stack.push(chars[++i]);
				break;
			case '-':
				System.out.print(stack.pop());
			}
		}

	}

}
